<!-- <div class="app-head" myApp="AppHead">
  <nav class="navbar navbar-default navbar-static-top head_nav" style="height: 1px;">
    <div class="container">
      <li><%= link_to '登出', session_path, method: :delete %></li>
    </div>
  </nav>
</div> -->

<div class="header white-bg">
  <div class="sidebar-toggle-box">
      <i class="fa fa-bars"></i>
  </div>
  <div class="link-to-index">
    <%= link_to sales_store_products_path(@normal_store_id), class: "logo", title: "商品首页" do %>
      Com<span>pany</span>
    <% end %>
  </div>

  <div class="search_form">
    <%= form_tag search_sales_store_products_path(@normal_store_id), method: 'get' do |f| %>
      <div class="form-group">
        <input type="text" name="name" value="<%= @search_name %>" class="form-control search-input" placeholder="搜索本站商品...">
        <button type="submit" class="btn seach-button">搜索</button>
      </div>
    <% end %>
  </div>




  <div class="top-nav">
    <%= link_to "定制产品", new_sales_custom_product_path(store_id: @normal_store_id), title: "无符合产品？自定义产品", class: "btn-append custom_cart_items" %>
        <ul class="nav pull-right top-menu">
          <% if current_customer.present?  %>
            <li class="dropdown">
                <a data-toggle="dropdown" class="dropdown-toggle js-toggle-profile" href="#">
                  <span class="username"> <%= current_customer.name %></span>
                </a>
                <ul class="dropdown-menu extended logout js-hiding sale_header_img">
                    <div class="log-arrow-up"></div>
                    <!-- <li><a href="#"><i class=" fa fa-suitcase"></i>Profile</a></li> -->
                    <li><a href="/sales/cart_items?store_id=<%= @normal_store_id %>"><i class="fa fa-shopping-cart" aria-hidden="true"></i> 购物车</a></li>
                    <li>
                      <%= link_to sales_custom_products_path(store_id: @normal_store_id) do %>
                        <i class="fa fa-creative-commons" aria-hidden="true"></i> 我的产品
                      <% end %>
                    </li>

                    <li>
                      <%= link_to sales_store_orders_path(store_id: @normal_store_id) do %>
                        <i class="fa fa-th-list"></i> 我的订单
                      <% end %>
                    </li>
                    <!-- <li><a href="#"><i class="fa fa-bell-o"></i> Notification</a></li> -->
                    <li><a href="/sales/session?store_id=<%= @store_id %>" data-method="delete" ><i class="fa fa-sign-out" aria-hidden="true"></i> 登出</a></li>
                </ul>
            </li>
          <% else %>
            <div class="sales_header_login_with_logout">
              <li><%= link_to '登录', new_sales_session_path(store_id: @store_id) %></li>
              <li><%= link_to '注册', new_sales_register_path(store_id: @store_id) %></li>
            </div>
          <% end %>
            <!-- <li class="sb-toggle-right">
                <i class="fa  fa-align-right"></i>
            </li> -->
        </ul>
    </div>
</div>
